<%@ page language="java" contentType="text/html;charset=UTF-8"%>
<html>
<head>
<title>AscentSys医药商务系统</title>
<meta http-equiv="content-type" content="text/html; charset=GB2312" />
<meta name="description" content="Your website description goes here" />
<meta name="keywords" content="your,keywords,goes,here" />
<link rel="stylesheet" href="/AscentSys/css/andreas08(blue).css" type="text/css" media="screen,projection" />
	<style type="text/css">
/* 页面字体样式 */
body, td, input {
    font-family:Arial;
    font-size:12px;
}
/* 表格基本样式 */
table.default {
    border-collapse:collapse;
    width:350px;
}
/* 表格单元格样式 */
table.default td {
    border:1px solid black;
    padding:3px;
}
/* 列头样式 */
table.default td.item {
    background:#0e59c0;
    color:#fff;
}
/* 正常信息样式 */
div.ok {
    color:#006600;
}
/* 警告信息样式 */
div.warning {
    color:#FF0000;
}
</style>
<script src="js/prototype-1.4.0.js" type="text/javascript"></script>
<script src="js/json.js" type="text/javascript"></script>
<script  language="javascript"  >
	function refresh(){
		//重新获取验证码图片的src属性
		document.getElementById("authImg").src='authImg?now='+new Date();
	}

	function checkUserName(){
		//请求的地址
		var url="registCheckAction.action";
		var params=Form.Element.serialize('username');
		//创建Ajax.Request对象，对应于发送请求
				var myAjax = new Ajax.Request(
				url,
				{
					//请求方式：POST
					method:'post',
					//请求参数
					parameters:params,
					//指定回调函数
					onComplete: processResponse,
					//是否异步发送请求
					asynchronous:true
				});
	}
	
	
	function processResponse(request)
			{
				var action = request.responseText.parseJSON();
				$("usernameCheckDiv").innerHTML = action.tip;
			}	

	function check(){
	if(form.username.value == "")
    {
       alert("用户名不能为空！"); 
       form.username.focus();
        return false;
    }
   if(form.password.value == "")
    {
        alert("请输入密码 ！");
        form.password.focus();
         return false;
    }
     if(form.password2.value == "")
    {
        alert("请再次输入密码 ！");
       form.password2.focus();
         return false;
    }
    if(form.password.value!=form.password2.value){
    
       alert("两次输入的密码不一致 ！");
        form.password2.focus();
         return false;
    }
    if(form.email.value == "")
    {
        alert("请输入邮件 ！");
        form.email.focus();
         return false;
    }
    
 var regm = /^[a-zA-Z0-9_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/;//验证Mail的正则表达式,^[a-zA-Z0-9_-]:开头必须为字母,下划线,数字,
  if (form.email.value!="" && !form.email.value.match(regm) )
   		 {
     		alert("邮件格式不对，检查后重新输入！");
	     	form.email.focus();
             return false;
   		 }  
   if(form.code.value==""){
   		alert("请输入验证码！");
        form.code.focus();
         return false;
   }
  else 
    return true;
}

</script>
</head>
<body> 
<form name="form" method="post" action="<%=request.getContextPath()%>/userAction.act">
<input name="method" type="hidden" value="userLogin"/>
	<div id="container" >
<div id="header">
<h1>加拿大・亚思晟科技 </h1>
<h2>Quality is everything!</h2>
</div>
<div id="navigation">
<ul>
<li class="selected"></li>
<li><a href="/AscentSys/index.jsp">首页</a></li>
<li><a href="/AscentSys/product/itservice.html">IT服务</a></li>
<li><a href="/AscentSys/product/products.html">医药商务系统</a></li>
<li><a href="/AscentSys/product/employee.html">员工招聘</a></li>
<li><a href="/AscentSys/product/ContactUs.html">关于我们</a></li>
<li></li>
</ul>
</div>
				<div id="content2">
					<table width="100%" height="41" border="0" align="center" cellpadding="0" cellspacing="0">
						<tr>
							<td width="15" height="18" align="left" valign="top"><div align="left"></div></td>
							<td width="385" align="left" valign="bottom" class="12">&nbsp;</td>
						</tr>
						<tr>
							<td height="4" colspan="2" align="left" valign="bottom"></td>
						</tr>
						<tr>
							<td height="15" align="left" valign="top">&nbsp;
							</td>
							<td height="15" align="left" valign="top" class="12">
							 <table width="100%" height="20" border="0" cellpadding="0"cellspacing="0">
								<tr><td height="20"><div class="right_proaducts"><font color="red">用户注册成功:</font>
												<br />
											</div>
										<DIV class=padding>
										<DIV id=middlebody>
													 <table width="150" border="0" cellspacing="0" cellpadding="0">
      <tr>
        <td width="30%" valign="middle"><img src="images\username.jpg" width="61" height="17" align="bottom" />
            <input name="username" id="username" type="text" size="7"/>
        </td>
      </tr>
      <tr>
        <td valign="middle"><img src="images\password.jpg" width="61" height="17" />
            <input name="password" id="password" type="password" size="6" /></td>
      </tr>
      <tr>
        <td height="30" valign="bottom"><input name="image" type="image" onclick="return checkLoginIndex(form);" src="images\login_1_7.jpg" alt="登录" width="44" height="17" border="0"/>
          </select></td>
      </tr>
    </table>			
										</div>
				<div id="footer">
					<p>
						<a href="http://www.ascenttech.com.cn/" target="_blank">版权所有：北京亚思晟商务科技有限公司
							&copy;2004-2008|京ICP备05005681</a>
					</p>
				</div>

			</div>
		</form>
	</body>
</html>
